/*
Copyright (C) Ariff Ehsan, Abdul Hadi Fikri

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
*/

/*  Author : Ariff Ehsan
 *  Date   : July 11, 2009
 *
 *  Log    : Jan 11, 2010 ? ariff ehsan
 *           - code cleanup, add comment
 */


#ifndef __ADC_H__
#define __ADC_H__

#if defined (__AVR_ATmega644P__)
#else
#error the configured microcontroller is not supported for this library
#endif


/**
 *  ADC initialization
 */
void ADC_init(void);


/**
 *  ADC register
 *  @event - function pointer
 */
void ADC_reg(void (*event)(uint16_t));


/**
 *  ADC read
 *  @pin - adc input pin
 */
void ADC_read(uint8_t pin);


#endif // __ADC_H__